package connection;

import java.io.IOException;
import java.net.Socket;

public class ControllerConnectionIn extends ConnectionIn {

	public ControllerConnectionIn(Socket socket, Relay relay) {
		super(socket, relay);
	}

	@Override
	protected void handleMessage() {
		try {
			int lane = dis.read();
			int sensor = dis.read();
			relay.addSensorMessage(new SensorMessage(lane, sensor));
		} 
		catch (IOException e) {
			e.printStackTrace();
		}
	}
}
